import { dashInfoModel } from './dashModel';

export default class qualityInfo {
  constructor(qn: number, desc: string, dash?: dashInfoModel) {
    this.qn = qn;
    this.desc = desc;
    if (dash) {
      dash.audio.forEach((i) => {
        this.audioUrls.push(i.baseUrl)
      });
      dash.video.forEach((i) => {
        if (i.id == qn)
          this.videoUrls.push(i.baseUrl)
      });
    }
  }

  qn: number;
  desc: string;
  audioUrls: Array<string>;
  videoUrls: Array<string>;
}